SetUserName

SoftwareShield ClientProtector COM Component > ClientProtector (SSCProtector) Reference > SetUserName

## SetUserName

The SetUserName function sets the User Name field in the currently loaded license.

###### Syntax

HRESULT SetUserName ( BSTR UserName );

###### Parameters

UserName

[IN] Wide character string (of any length) which must be contain the User Name field you wish to set in the currently loaded license.

###### Remarks

The SetUserName function sets the User Name field in the currently loaded license. Once executed, any previously stored value in the User Name field is overwritten.

This field is a dynamically allocated string and has no declared maximum length. The theoretical maximum length of this string value is 2GB (two gigabytes). In practice this means that the maximum length of this string is limited only by the amount of memory available to your application.

###### Return Value

As with all COM function calls they return an HRESULT. HRESULT is a data type that is a 32-bit error or warning code. Check your compilers documentation for information on interpreting the HRESULT value.

###### Function Information

Exposed By Interface: | "ISSCProtector"
Exposed In COM Server Binaries: | "SSCProt.dll" and "SSCProtD.dll"